Image masks can be large, typically requiring 8-bits (one byte) per pixel. An image with 240×60 dimensions requires 14,400 bytes to for an uncompressed mask. This is entirely practical on mainstream computers and mobile devices, which have gigabytes of RAM and storage. However, for embedded devices (e.g. IoT devices) with limited RAM (48 KB) and ROM (1 MB), this easily becomes too large for practical use. For storage, the mask may be compressed. One common way to do this is using the PNG algorithm. The processing power and, in particular memory, required to run the PNG decoder (approximately 45 KB overhead) make it impractical on limited hardware with limited functionality.
One method of compression which is appropriate for limited capacity devices is U.S. Pat. No. 5,768,569 which uses a type of run-length encoding method. As shown in FIG. 7, a line 705 of a mask for a glyph 700 comprising 18 pixels can be represented, uncompressed, with 18 bytes 720. Using the methods described by this patent, the mask can be represented with 15 bytes 730. However, given the reduced of resolution on many small form factor displays used in certain limited power devices, even more compression is desired because such displays have limited display capability (resolution and/or color) in addition to the limited RAM and storage resources.
There therefore exists a need for higher compression for bitmaps in limited capacity devices